{include file="public/header"}
</head>
<body>
<div class="panel admin-panel margin-top">
    <div class="panel-head" id="add"><strong><span class="icon-pencil-square-o"></span>添加内容</strong></div>
    <div class="body-content">
        <form method="post" class="form-x" action="{:url('Auth/authEdit')}">
            <input type="hidden" name="id" value="{$line['id']}">
            <div class="form-group">
                <div class="label">
                    <label>名称：</label>
                </div>
                <div class="field">
                    <input type="text" class="input w50" name="aname" id="tname" value="{$line['title']}"/>
                </div>
            </div>

            <div class="form-group">
                <div class="label">
                    <label>权限：</label>
                </div>
                <div class="field">
                    {foreach $list as $v}
                    <input type="checkbox" name="auths[]" value="{$v['id']}" {if in_array($v['id'],$line['rules'])}checked{/if}/>{$v['title']}  &nbsp;
                    {/foreach}
                </div>
            </div>
            <div class="form-group">
                <div class="label">
                    <label></label>
                </div>
                <div class="field">
                    <!--<input type="hidden" name="action" value="add">-->
                    <button class="button bg-main icon-check-square-o" type="submit"> 提交</button>
                </div>
            </div>
        </form>
    </div>
</div>
</body>
</html>